package com.xbongbong.saas.domain.entity;

import com.alibaba.fastjson.JSONObject;
import com.xbongbong.paas.toolbox.util.DateUtil;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

/**
 * 表单草稿实体
 *
 * @author GuoJun.HU
 * @date 2019/2/19 19:15
 * @since V1.0
 */
@Getter
@Setter
@ToString
public class FormDataDraftEntity {
    /**
     * 主键
     */
    private Long id;
    /**
     * 公司id
     */
    private String corpid;
    /**
     * 用户id
     */
    private String userId;
    /**
     * 应用id
     */
    private Long appId;
    /**
     * 菜单id
     */
    private Long menuId;
    /**
     * 表单id
     */
    private Long formId;
    /**
     * 区分SaaS和PaaS
     */
    private Integer saasMark;
    /**
     * 区分SaaS的业务
     */
    private Integer businessType;
    /**
     * 表单数据
     */
    private JSONObject data;
    /**
     * 创建时间时间戳
     */
    private Long addTime;
    /**
     * 更新时间时间戳
     */
    private Long updateTime;
    /**
     * 删除标记
     */
    private Integer del;

    public FormDataDraftEntity() {
        this.businessType = 0;
        this.addTime = (long) DateUtil.getInt();
        this.updateTime = (long) DateUtil.getInt();
        this.del = 0;
    }
}
